import service from './index'

//按需导出
export function zyglPageCount(data) {
    return service({
        url: '/admin/major/page/count',
        method: 'get',
        params:data
    })
}
export function zyglPage(data,page) {
    return service({
        url: '/admin/major/page/'+page,
        method: 'get',
        params:data
    })
}
export function zyglAdd(data) {
    return service({
        url: '/admin/major',
        method: 'post',
        data:data
    })
}
export function departmentAll() {
    return service({
        url: '/admin/department/names',
        method: 'get',
    })
}
//详情
export function zyglDetail(id) {
    return service({
        url: '/admin/major/'+id,
        method: 'get',  
    })
}
//编辑
export function zyglEdit(data) {
    return service({
        url: '/admin/major',
        method: 'put',
        data:data  
    })
}
//删除
export function zyglDelete(id) {
    return service({
        url: '/admin/major/'+id,
        method: 'delete',

    })
}